/**
 * Created by Jone on 2016/7/12.
 */
var mongoose = require('mongoose');
var Schema = mongoose.Schema;

var InterfaceSchema = new Schema({
    name: String, //接口名称
    desc: String, //接口用途
    method: String, //GET,POST,PUT,DELETE,PATCH,HEAD,OPTIONS
    groupId: {type : Schema.Types.ObjectId, ref: 'Group'},  //分组Id
    path: String,  //调用地址
    contentType: String, //请求类型
    request: String, //请求格式
    response: String, //响应格式
    remark: String, //备注
    createAt:{type: Date, default: Date.now}, //创建时间
    updateAt: {type: Date, default: Date.now} //更新时间
});
exports.Interface = mongoose.model('Interface', InterfaceSchema);